<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>数据库信息</title>
    <link rel="stylesheet" href="../static/admin/js/layui/css/layui.css">
    <link rel="stylesheet" href="css/install.css">
</head>
<body>

<!-- main -->
<div class="layui-main">
    <h1 class="site-h1">数据库信息</h1>
    <!-- database online -->
    <form class="layui-form" action="index.php?type=d_success" method="post" lay-filter="form">
        <div class="layui-form-item">
            <label class="layui-form-label">地址</label>
            <div class="layui-input-inline">
                <input type="text" name="DB_HOST" required lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input" value="127.0.0.1" />
            </div>
            <label class="layui-form-label">端口</label>
            <div class="layui-input-inline">
                <input type="text" name="DB_PORT" required lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input" value="3306" />
            </div>
            <div class="layui-input-inline">
                <select name="DB_TYPE" lay-verify="required" required>
                    <option value="mysql">mysql</option>
                    <option value="mssql">mssql</option>
                </select>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">数据库名</label>
            <div class="layui-input-inline">
                <input type="text" value="kblite" name="DB_NAME" required lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input" />
            </div>
            <label class="layui-form-label">表前缀</label>
            <div class="layui-input-inline">
                <input type="text" value="ykb_" name="DB_PREFIX" required lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input" />
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">数据库账号</label>
            <div class="layui-input-inline">
                <input type="text" value="root" name="DB_USER" required lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input" />
            </div>
            <label class="layui-form-label">数据库密码</label>
            <div class="layui-input-inline">
                <input type="text" name="DB_PWD" placeholder="请输入" autocomplete="off" class="layui-input" />
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">后台账号</label>
            <div class="layui-input-inline">
                <input type="text" value="admin" name="username" required lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input" />
            </div>
            <label class="layui-form-label">后台密码</label>
            <div class="layui-input-inline">
                <input type="text" name="password" placeholder="请输入" required lay-verify="required" autocomplete="off" class="layui-input" />
            </div>
        </div>
        <div class="layui-form-item">
            <div class="btn-box">
                <a class="layui-btn layui-btn-small layui-btn-normal" href="./index.php?type=<?php echo $config['checkPage']?>">上一步</a>
                <button type="submit" class="layui-btn layui-btn-small" lay-submit >创建数据</button>
            </div>
        </div>
    </form>

    <!-- text -->
    <!--<blockquote class="layui-elem-quote" style="height: 250px;overflow-y:scroll;display: none" id="text">
        <h1 id="az">安装进度</h1>
        <p>ykb_admin_user 安装成功</p>
        <p>ykb_admin_user 安装成功</p>
    </blockquote>-->
</div>

<!--<a href="./index.php?type=<?php echo $config['endPage']; ?>"><button>同意</button></a>-->
<script type="text/javascript" src="../static/admin/js/layui/layui.js"></script>
<script>
layui.use(['form','layer','jquery'], function(){
    var form = layui.form(),layer = layui.layer,$ = layui.jquery;

    //监听提交
    form.on('submit(form)', function(data){
        layer.load(0, {
            shade: [0.2,'#000'] //0.1透明度的白色背景
        });
    });
});
</script>
</body>
</html>